;;;From The Swamp http://www.theswamp.org/index.php?topic=35588.0
;;;with minor edits to symbol names and added limits for int color values
(defun truecolor (aColor / objColor)
  (setq objColor (vla-getinterfaceobject (vlax-get-acad-object) (strcat "AutoCAD.AcCmColor." (substr (getvar "acadver") 1 2))))
  (cond
    ((and (>= aColor 0)(< aColor 257)(= (type aColor) 'INT))
     (vla-put-ColorMethod objColor acColorMethodByACI)
     (vla-put-ColorIndex objColor aColor))
    ((not (listp aColor)) nil)
    ((= (length aColor) 3)
     (vla-put-ColorMethod objColor acColorMethodByRGB)
     (vla-SetRGB objColor (car aColor) (cadr aColor) (last aColor)))
    ((= (length aColor) 2)
     (vla-SetColorBookColor objColor (car aColor) (cadr aColor)))
  ); cond
  objColor
); truecolor
(PRINC)
